#include <stdio.h>
#include <string.h>
#include <mysql/mysql.h>
void delete_subject(MYSQL *mysql)
{
	printf("        3.删除课程表数据        \n"); 	
	char data[200];
	int id;
	int f=0;                                                          
	printf("输入要删除的课程ID:");                             
	scanf("%d",&id);
	sprintf(data,"delete from subject where id=%d",id); 
	f = mysql_real_query(mysql, data, strlen(data));         
	if (0 != f) 
	{                                                           
		printf("删除该课程的信息失败!\n");         
	}
	else
	{
		printf("删除该课程的信息成功!\n");
	}
}
